/**
 *  设备相关接口
 * **/

import request from '@/common/request.js'
import {HTTP_REQUEST_URL,http_request_url_java} from '@/config.js' 

const yfk_api={}

// 获取生境 
yfk_api.getEnvtype = data => request.globalRequest({
	methods: 'POST',
	url: HTTP_REQUEST_URL+'/project/commondata',   
	data: data   
}) 

// 上传数据 
yfk_api.addFkData = data => request.globalRequest({
	methods: 'POST',
	url: HTTP_REQUEST_URL+'/yfk/addfkdata',   
	data: data   
}) 

// 云防控项目 
yfk_api.userProject = data => request.globalRequest({
	methods: 'POST',
	url: HTTP_REQUEST_URL+'/yfk/user-project',   
	data: data   
}) 



// 获取天气信息  (高德api)
yfk_api.getWeather = data => request.vGet({ 
	url: 'https://restapi.amap.com/v3/weather/weatherInfo',   
	data: data   
}) 

// 获取位置详细信息 (高德api)
yfk_api.getCityInfo = data => request.vGet({ 
	url: 'https://restapi.amap.com/v3/geocode/regeo',   
	data: data   
}) 



// 商家向用户转账
yfk_api.sendRedpacketByApp = data => request.vPost({  
	url: 'http://shop.honghuoyi.com/index.php/mobile/redpacket/sendRedpacketByApp.html',   
	data: data   
})  

// 获取红包口令
yfk_api.getKoling = data => request.vGet({ 
	url: 'http://shop.honghuoyi.com/index.php/mobile/redpacket/getword',   
	data: data   
})  

// 获取红包口令
yfk_api.saveKl = data => request.globalRequest({ 
	methods: 'POST',
	url: HTTP_REQUEST_URL+'/yfk/savekl',   
	data: data   
}) 

 

// 上传轨迹信息 
yfk_api.addLocus = data => request.globalRequest({
	methods: 'POST',
	url: HTTP_REQUEST_URL+'/yfk/locus',   
	data: data   
})

// 上传轨迹信息 
yfk_api.adCode = data => request.globalRequest({
	methods: 'POST',
	url: HTTP_REQUEST_URL+'/yfk/adcode',   
	data: data   
})

// 上传轨迹信息 
yfk_api.addMarkers = data => request.globalRequest({
	methods: 'POST',
	type:2,
	url: http_request_url_java+'/yfkpro/addMarkers',   
	data: data   
})

// 上传轨迹信息 
yfk_api.addUserLocus = data => request.globalRequest({
	methods: 'POST',
	type:2,
	url: http_request_url_java+'/yfkpro/addUserLocus',   
	data: data   
})

// 获取省份列表 
yfk_api.getProvince= data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/yun/area-list',   
	data: data   
})

// 获取街道 
yfk_api.getStreet= data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/yun/street',   
	data: data   
})

// 获取查询数据 
yfk_api.getdataInfo= data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/yfk/data-info',   
	data: data   
})

// 获取防控列表 
yfk_api.getFkDataList= data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/yfk/fkdatalist',   
	data: data   
})

// 获取防控数据详情 
yfk_api.getfkDataDetail= data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/yfk/fkdata',   
	data: data   
})

// 删除数据 
yfk_api.deleteData= data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/yfk/deletedata',   
	data: data   
})


// 领取红包
yfk_api.sendQmfkRedPack = data => request.globalRequest({
	methods: 'POST',
	type:2,
	url: http_request_url_java+'/others/sendQmfkRedPack',   
	data: data   
})

// 是否有证书判断
yfk_api.checkCertificate = data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/ccie/isallow',   
	data: data   
})

// 上传证书信息
yfk_api.addCertificate = data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/ccie/add',   
	data: data   
})

// 证书详情信息
yfk_api.certificateInfo = data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/ccie/ccieinfo',   
	data: data   
})

// 检测是否还需要提交实操数据
yfk_api.yfkminnum = data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/ccie/yfkminnum',   
	data: data   
})

// 编辑证书
yfk_api.editCertificate = data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/ccie/edit',   
	data: data   
})

// 获取红包记录列表
yfk_api.getRedpackList = data => request.globalRequest({
	methods: 'POST', 
	url: HTTP_REQUEST_URL+'/user/uredpackls',   
	data: data   
})
 


  
export default yfk_api






